//
//  CLWebViewController.m
//  CL1024
//
//  Created by liu nian on 13-2-16.
//  Copyright (c) 2013年 liunian. All rights reserved.
//

#import "CLWebViewController.h"

@interface CLWebViewController ()

@end

@implementation CLWebViewController

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)viewDidLoad
{
    [super viewDidLoad];
    
    self.navigationController.navigationBarHidden = NO;
    
    NSURL *url = [NSURL URLWithString:self.urlString];
    NSURLRequest *request  = [NSURLRequest requestWithURL:url];
    [self.webview loadRequest:request];

}

- (void)webViewDidStartLoad:(UIWebView *)webView
{
    [MBProgressHUD showHUDAddedTo:self.view animated:YES];
}
- (void)webViewDidFinishLoad:(UIWebView *)webView
{
    [MBProgressHUD hideAllHUDsForView:self.view animated:YES];
}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (void)dealloc {
    [_urlString release];
    [_webview release];
    [super dealloc];
}
- (void)viewDidUnload {
    [self setWebview:nil];
    [super viewDidUnload];
}
@end
